package com.gemantic.result;

import org.springframework.http.HttpStatus;
import org.springframework.http.ResponseEntity;

/**
 * Created by zwzhou on 2016/12/6.
 */
public class Responses {

    public static ResponseEntity<Response<Void>> ok() {
        return new ResponseEntity<Response<Void>>(Response.ok(), HttpStatus.OK);
    }

    public static <T> ResponseEntity<Response<T>> ok(T data) {
        return new ResponseEntity<Response<T>>(Response.ok(data), HttpStatus.OK);
    }
}
